{% extends "root_base.html" %}{% block content_root_base %}
	<div id="addform_link"><p><strong>添加友情链接：</strong><form action="/managelink_root.html" method="post">
		<table width="50%" border="0">
		<tr><td align="right">链接名称：<input type="text" name="name_link" /></td></tr>
		<tr><td align="right">链接地址：<input type="text" name="url_link" /></td></tr>
		<tr><td align="right">链接描述：<input type="text" name="title_link" /></td></tr>
		<tr><td align="right">
			<input type="hidden" name="type_submit" value="add" />
			<input type="submit" value="提交添加" />
		</td></tr></table>
	</form></div>
	<p><strong>修改/删除友情链接</strong></p>
	<table class="width_full" border="0">
	<tr><td><strong>链接名称</strong></td><td><strong>链接地址</strong></td><td><strong>链接描述</strong></td><td><strong>删除</strong></td><td align="right"><strong>提交</strong></td></tr>
	{% for link in links %}
	<form action="/managelink_root.html" method="post"><tr>
		<td><input type="text" value="{{ link.name }}" name="name_link" /></td>
		<td><input type="text" value="{{ link.url }}" name="url_link" /></td>
		<td><input type="text" value="{{ link.title }}" name="title_link" /></td>
		<td>
			<input type="hidden" value="{{ link.key }}" name="key_link" />
			<input type="checkbox" value="delete" name="checkbox_delete" id="{{ link.key }}_checkbox" />
			<label for="{{ link.key }}_checkbox">Del</label>
		</td>
		<td align="right">
			<input type="hidden" name="type_submit" value="edit_del" />
			<input type="submit" value="提交" />
		</td>
	</tr></form>
	{% endfor %}</table>
{% endblock %}
